class Merchant {
  String address;
  int bankCompanyRelaId;
  String editDate;
  String headerUrl;
  String liquidationName;
  int merchantId;
  String merchantName;
  int merchantState;
  int merchantType;
  String mobile;
  int registerType;
  int payType;
  bool isOfficial;
  String name;

  Merchant(this.merchantName, this.merchantState);

  static Merchant fromMap(Map<String, dynamic> map) {
    if (map == null) return null;
    Merchant merchant = Merchant('', 0);
    merchant.address = map["address"];
    merchant.bankCompanyRelaId = map["bankCompanyRelaId"];
    merchant.editDate = map["editDate"];
    merchant.headerUrl = map["headerUrl"];
    merchant.liquidationName = map["liquidationName"];
    merchant.merchantId = map["merchantId"];
    merchant.merchantName = map["merchantName"];
    merchant.merchantState = map["merchantState"];
    merchant.merchantType = map["merchantType"];
    merchant.mobile = map["mobile"];
    merchant.registerType = map["registerType"];
    merchant.payType = map["payType"];
    merchant.isOfficial = map["isOfficial"];
    merchant.name = map["name"];
    return merchant;
  }
}
